<div class="contents">
  <ol class="breadcrumb">
    <li><a href="#/index/panel">首页</a></li>
    <li class="active">内部理财师汇总</li>
  </ol>
  <form class="form-inline search-box" role="form" ng-submit="search()" novalidate>


     <div class="form-group" style="font-size: 14px;margin-left: 60px;">
       财富中心/理财师姓名:
       <select type="text" class="form-control" placeholder="服务顾问" ng-options="m.userId as m.username for m in licaishiManagerUserList" ng-model="searchMap.systemUserId" style="width:200px;">
      </select>
    </div> 
    <div class="form-group" style="font-size: 14px;margin-left: 60px;">
      客户是否注册:
      <select class="form-control" style="    width: 200px;" placeholder="是否注册" ng-model="searchMap.isReg">
        <option value="">--不限--</option>
        <option value="0">否</option>
        <option value="1">是</option>
      </select>
    </div>
    <br/>
    <div class="form-group" style="font-size: 14px;margin-left: 60px;">
      客户认证状态:
      <select class="form-control" style="margin-left:48px;width: 200px;" placeholder="认证" ng-model="searchMap.authStatus" ng-options="m.value as m.text for m in dictMap.rzMapModel" ><option value="">--不限--</option></select> 
    </div> 
    <div class="form-group" style="font-size: 14px;    margin-left: 60px;">
    是否拨打回访:
      <select class="form-control" style="    width: 200px;" placeholder="是否回访" ng-model="searchMap.isVist">
        <option value="">--不限--</option>
        <option value="2">否</option>
        <option value="1">是</option>
      </select>
    </div>
    <br/>
    <span style="font-size: 14px;margin-left: 60px;">时间范围：</span>
     <div class="form-group" style="font-size: 14px;margin-left: 60px;">
      从&nbsp;&nbsp;<input type="date" class="form-control" placeholder="开始日期,如2015-01-01" ng-model="searchMap.startDate" maxlength="10">
    </div> 
    <div class="form-group" style="font-size: 14px;">
      至&nbsp;&nbsp;<input type="date" class="form-control" placeholder="结束日期,如2015-01-01" ng-model="searchMap.endDate" maxlength="10">
    </div>  

    <button type="submit" class="btn btn-primary">查询</button>
  </form>
<div>
  <button  type="button" class="btn btn-primary" ng-click="isShowDetail=false;">内部理财师-汇总</button> 

  <button  type="button" class="btn btn-primary" style="margin-left:30px" ng-click="isShowDetail=true;">内部理财师-详情</button>
</div>

<div ng-if="!isShowDetail">
  <table class="table table-striped table-hover">
    <div style="font-size: 20px;margin-top: 5px;background-color: #eee;">
      内部理财师-汇总  
      <button type="button" style="float: right;height: 30px;margin-right: 100px;" class="btn btn-primary" ng-click="export(2)" has-auth where="btn" who="LCS_MAN_STATICTICS_CSV">导出CSV</button>
      <span  ng-if="searchMap.startDate||searchMap.endDate">
      （{{searchMap.startDate||'~'}}至{{searchMap.endDate||'~'}}）
      </span>
      <span ng-if="!searchMap.startDate&&!searchMap.endDate">
      （全部）
      </span>
    </div>
    <thead>
      <tr>
        <th width="65">理财师姓名</th>
        <th width="80">邀请函分享次数</th>
        <th width="80">邀请函吸引注册数</th>
        <th width="110">邀请函吸引认证会员数</th>
        <th width="100">邀请函会员转化率</th>
        <th width="80">系统分配客户数</th>
		    <th width="90">系统分配客户注册数</th>
        <th width="110">系统分配客户认证会员数</th>
        <th width="100">系统分配会员转化率</th>
      </tr>
    </thead>

    <tbody>
      <tr ng-repeat="fa in item">
        <td>{{fa.username}}</td>
        <td>{{fa.shareCount}}</td>
        <td>{{fa.shareRegCount}}</td>
        <td>{{fa.shareAuthCount}}</td>
        <td>{{fa.shareRegAuthRatio}}</td>
        <td>{{fa.sysCount}}</td>
        <td>{{fa.sysRegCount}}</td>
        <td>{{fa.sysAuthCount}}</td>
        <td>{{fa.sysRegAuthRatio}}</td>
      </tr>
    </tbody>
  </table>
  </div>
<div ng-if="isShowDetail">
  <table class="table table-striped table-hover" >
    <div style="font-size: 20px;margin-top: 5px;background-color: #eee;">
      内部理财师-详情
    <select style="float: right;font-size:14px" ng-change="changePageSize()" ng-model="config.setPageSize">
        <option value="50">50</option>
        <option value="100">100</option>
     </select>
    <button style="float: right;margin-right: 50px;height: 30px" type="button" class="btn btn-primary"  ng-click="export(1)" has-auth where="btn" who="LCS_MAN_DETAIL_CSV">导出CSV</button>

      <span ng-if="searchMap.startDate||searchMap.endDate">
      （{{searchMap.startDate||'~'}}至{{searchMap.endDate||'~'}}）
      </span>
      <span ng-if="!searchMap.startDate&&!searchMap.endDate">
      （全部）
      </span>
    </div>
    <thead>
      <tr>
        <th width="65">理财师姓名</th>
        <th width="80">客户手机号</th>
        <th width="80">客户来源</th>
        <th width="110">系统分配时间</th>
        <th width="100">注册时间</th>
        <th width="80">是否注册</th>
        <th width="90">最后回访时间</th>
        <th width="110">提交认证时间</th>
        <th width="100">通过认证时间</th>
      </tr>
    </thead>

    <tbody>
      <tr ng-repeat="it in itemDetail">
        <td>{{it.uName}}</td>
        <td>{{it.uLoginName}}</td>
        <td>{{it.clientSource }}</td>
        <td>{{it.sysAllocatedTime|limitTo:19}}</td>
        <td>{{it.regTime|limitTo:19}}</td>
        <td>{{it.isRegister=='1'?"是":"否"}}</td>
        <td>{{it.lastVistDate|limitTo:19}}</td>
        <td>{{it.addAuthDate|limitTo:19}}</td>
        <td>{{it.authPassDate|limitTo:19}}</td>
      </tr>
    </tbody>
  </table>
  <div class="pager-box" ng-include src="'tpl/public/pager.html'" ng-show="itemDetail.length > 0"></div>
 
</div>

</div>